//
//  HeaderCollectionViewCell.m
//  14-HomeWork
//
//  Created by dllo on 16/8/2.
//  Copyright © 2016年 dllo. All rights reserved.
//

#import "HeaderCollectionViewCell.h"
@interface HeaderCollectionViewCell ()
@property (nonatomic, strong)UIImageView *imageView;
@property (nonatomic, strong)UILabel *titleLable;
@property (nonatomic, strong)UILabel *detailLabel;
@end
@implementation HeaderCollectionViewCell
- (instancetype)initWithFrame:(CGRect)frame {
    self = [super initWithFrame:frame];
    if (self) {
        self.backgroundColor = [UIColor redColor];
        _imageView = [[UIImageView alloc] initWithFrame:CGRectMake(0, 10, CGRectGetWidth(frame) * 1 / 2, CGRectGetHeight(frame) - 20)];
        _imageView.image = [UIImage imageNamed:@"ximiannai-1"];
        [self addSubview:_imageView];
        _titleLable = [[UILabel alloc] initWithFrame:CGRectMake(CGRectGetWidth(frame) * 1 / 2, 20, CGRectGetWidth(frame) / 2, _imageView.frame.size.height / 4)];
        _titleLable.text = @"Taste新奇体验馆";
        _titleLable.font = [UIFont systemFontOfSize:15];
        [self addSubview:_titleLable];
        
        _detailLabel = [[UILabel alloc] initWithFrame:CGRectMake(CGRectGetWidth(frame) * 1 / 2, 20 + _titleLable.frame.size.height, CGRectGetWidth(frame) / 2, _imageView.frame.size.height / 2)];
        _detailLabel.text = @"更新至第三期  W-unique";
        _detailLabel.numberOfLines = 0;
        _detailLabel.textColor = [UIColor colorWithRed:0.64 green:0.64 blue:0.64 alpha:1.00];
        [self addSubview:_detailLabel];
    }
    return self;
}
@end
